package Thread;

public class demo2 {
    public static void main(String[] args) {
        Thread t = new Thread(() -> {
            System.out.println("hello bit");
        },"新线程！");
        System.out.println(t.isAlive());
        try {
            Thread.sleep(2000);
        } catch (InterruptedException e) {
            throw new RuntimeException(e);
        }
        t.start();
        System.out.println(t.isAlive());

        try {
            Thread.sleep(2000);
        } catch (InterruptedException e) {
            throw new RuntimeException(e);
        }
        System.out.println("hello byte");

        System.out.println(t.isAlive());

    }
}
